﻿using System;
using System.Collections.Generic;
using DesignPattern.Builder.Computer;

namespace DesignPattern.Builder
{
    public class BuilderIBMComputer : AbsBuilderComputer
    {
        public BuilderIBMComputer()
        {
            this.computer = new Computer.Computer();
        }

        public override void SetHost()
        {
            Console.WriteLine("设置IBM主机");
            this.computer.host = new Host() {  Type = "i-h-2014-01", Name = "屌丝", ProductionDate = DateTime.Now.AddYears(-10)};
        }

        public override void SetKeyboarder()
        {
            Console.WriteLine("设置IBM键盘");
            this.computer.keyboard = new Keyboarder() { Type = "i-k-2014-01", Name = "你妹", ProductionDate = DateTime.Now.AddYears(-5) };
        }

        public override void SetMouse()
        {
            Console.WriteLine("设置IBM鼠标");
            this.computer.mouse = new Mouse() {  Type = "i-m-2014-01", Name= "浮云", ProductionDate = DateTime.Now.AddYears(-3)};
        }
    }

}
